﻿CREATE TABLE [dbo].[Database] (
    [DatabaseID]                  UNIQUEIDENTIFIER NOT NULL,
    [ServiceInstanceID]           UNIQUEIDENTIFIER NULL,
    [DiskSizeRequired]            BIGINT           NULL,
    [DisplayName]                 VARCHAR (200)    NULL,
    [Name]                        VARCHAR (200)    NULL,
    [NeedsUpgrade]                BIT              NULL,
    [NeedsUpgradeIncludeChildren] BIT              NULL,
    [Password]                    VARCHAR (200)    NULL,
    [TypeName]                    VARCHAR (200)    NULL,
    [Username]                    VARCHAR (200)    NULL,
    [CurrentSiteCount]            INT              NULL,
    [MaximumSiteCount]            INT              NULL,
    [PreferredTimerServer]        VARCHAR (200)    NULL,
    [WarningSiteCount]            INT              NULL,
    CONSTRAINT [PK_Database] PRIMARY KEY CLUSTERED ([DatabaseID] ASC),
    CONSTRAINT [FK_Database1_ServiceInstance] FOREIGN KEY ([ServiceInstanceID]) REFERENCES [dbo].[ServiceInstance] ([ServiceInstanceID])
);

